export const tableOption = {
  border: true,
  index: true,
  indexLabel: "序号",
  stripe: true,
  menuAlign: "center",
  align: "center",
  searchMenuSpan: 6,
  labelWidth: 140,
  dialogWidth: "40",
  viewBtn: true,
  menuWidth: 150,
  viewBtnIcon: " ",
  delBtnIcon: " ",
  editBtnIcon: " ",
  column: [
    {
      type: "month",
      label: "月份",
      prop: "month",
      span: 24,
      required: true,
      search: true,
      searchSpan: 4,
      rules: [
        {
          required: true,
          message: "月份不能为空",
        },
      ],
      format: "yyyy/MM", // 显示格式为年月，如2025年04月
      valueFormat: "yyyy/MM", // 输出格式为年月，如2025-04，字符串类型
    },
    {
      type: "date",
      label: "检验日期",
      prop: "checkDate",
      span: 24,
      required: true,
      search: true,
      searchSpan: 4,
      rules: [
        {
          required: true,
          message: "检验日期不能为空",
        },
      ],
      format: "yyyy/MM/dd", // 显示格式为年月，如2025年04月
      valueFormat: "yyyy/MM/dd", // 输出格式为年月，如2025-04，字符串类型
    },
    {
      type: "select",
      label: "时段",
      prop: "timePeriod",
      span: 24,
      /*     required: true,
      rules: [
        {
          required: true,
          message: "时段不能为空"
        }
      ],*/
      dicUrl: "/admin-api/system/dict-data/type?type=time_period",
      props: {
        label: "label",
        value: "label",
      },
      dicMethod: "get",
    },
    {
      type: "select",
      label: "车间",
      prop: "workShopName",
      span: 24,
      required: true,
      search: true,
      searchSpan: 5,
      rules: [
        {
          required: true,
          message: "车间不能为空",
        },
      ],
      dicUrl: "/admin-api/o3-pfoc/workshop/getWorkshopList",
      dicMethod: "get",
      props: {
        label: "workshopName",
        value: "workshopName",
      },
      cascader: ["lineName"],
    },
    {
      type: "select",
      label: "产线",
      prop: "lineName",
      span: 24,
      // required: true,
      search: true,
      searchSpan: 5,
      /*rules: [
        {
          required: true,
          message: "产线不能为空"
        }
      ],*/
      dicUrl:
        "/admin-api/o3-pfoc/realityproductlinemain/getLineListByWorkshopName?workshopName={{workShopName}}",
      dicMethod: "get",
      props: {
        label: "realityLineName",
        value: "realityLineName",
      },
    },
    {
      type: "input",
      label: "产品",
      prop: "product",
      span: 24,
      required: true,
      rules: [
        {
          required: true,
          message: "产品不能为空",
        },
      ],
    },
    {
      type: "input",
      label: "合格放行批次",
      prop: "approvedBatch",
      span: 24,
      required: true,
      rules: [
        {
          required: true,
          message: "合格放行批次不能为空",
        },
      ],
    },
    {
      type: "input",
      label: "批退批次",
      prop: "rejectedBatch",
      span: 24,
      required: true,
      rules: [
        {
          required: true,
          message: "批退批次不能为空",
        },
      ],
    },
    {
      type: "input",
      label: "批退率",
      prop: "rejectionRate",
      span: 24,
      required: true,
      rules: [
        {
          required: true,
          message: "批退率不能为空",
        },
      ],
    },
    {
      type: "input",
      label: "总不良数量",
      prop: "totalDefects",
      span: 24,
      required: true,
      rules: [
        {
          required: true,
          message: "总不良数量不能为空",
        },
      ],
    },
    {
      type: "input",
      label: "综合不良率",
      prop: "overallDefectRate",
      span: 24,
      required: true,
      rules: [
        {
          required: true,
          message: "综合不良率不能为空",
        },
      ],
    },
    {
      type: "input",
      label: "下线数量",
      prop: "offlineQty",
      span: 24,
      required: true,
      rules: [
        {
          required: true,
          message: "下线数量不能为空",
        },
      ],
    },
    {
      type: "input",
      label: "检验数量",
      prop: "checkQty",
      span: 24,
      required: true,
      rules: [
        {
          required: true,
          message: "检验数量不能为空",
        },
      ],
    },
    {
      type: "input",
      label: "抽样比例",
      prop: "amplingRatio",
      span: 24,
      required: true,
      rules: [
        {
          required: true,
          message: "抽样比例不能为空",
        },
      ],
    },
  ],
};
